package com.sms.jiujia.ui.setting;

import com.sms.jiujia.model.City;
import javafx.scene.control.Button;
import javafx.scene.control.ChoiceBox;
import javafx.scene.control.TextArea;
import javafx.scene.text.Font;
import javafx.scene.text.Text;

/**
 * @author songmingsong
 * @date 2023/5/6
 */
public class PositionSetting {
    public static void set(Setting setting) {
        TextArea textArea = setting.getTextArea();
        textArea.setLayoutX(215);
        textArea.setLayoutY(130);
        textArea.setPrefHeight(240);
        textArea.setPrefWidth(210);

        ChoiceBox<City> cityBox = setting.getCityBox();
        cityBox.getSelectionModel().selectFirst();
        cityBox.setLayoutX(360);
        cityBox.setLayoutY(15);
        cityBox.setPrefHeight(40);
        cityBox.setPrefWidth(65);
        cityBox.setMaxHeight(200);

        Button btnTest = setting.getBtnTest();
        btnTest.setLayoutX(155);
        btnTest.setLayoutY(15);
        btnTest.setPrefHeight(40);
        btnTest.setPrefWidth(65);

        Button btnStart = setting.getBtnStart();
        btnStart.setLayoutX(230);
        btnStart.setLayoutY(15);
        btnStart.setPrefHeight(40);
        btnStart.setPrefWidth(65);

        Button btnStop = setting.getStopBtn();
        btnStop.setLayoutX(360);
        btnStop.setLayoutY(75);
        btnStop.setPrefHeight(40);
        btnStop.setPrefWidth(65);

        Text notice = setting.getNotice();
        notice.setLayoutX(10);
        notice.setLayoutY(150);
        notice.setWrappingWidth(200);
        notice.setFont(new Font(12));

        Button setPushDeerKeyBtn = setting.getSetPushDeerKeyBtn();
        setPushDeerKeyBtn.setLayoutX(15);
        setPushDeerKeyBtn.setLayoutY(15);
        setPushDeerKeyBtn.setPrefHeight(40);
        setPushDeerKeyBtn.setPrefWidth(125);

        Text choiceBoxTitle = setting.getChoiceBoxTitle();
        choiceBoxTitle.setLayoutX(308);
        choiceBoxTitle.setLayoutY(40);
        choiceBoxTitle.setFont(new Font(16));

        Button getKeyMethodBtn = setting.getGetKeyMethodBtn();
        getKeyMethodBtn.setLayoutX(15);
        getKeyMethodBtn.setLayoutY(345);

    }
}
